#version 330 core

uniform vec3 lightDir;

in vec3 vEyeNormal;
in vec3 color;
uniform float alpha;

void main(void)
{
    vec3 L = normalize(lightDir);
    float NL = max(dot(normalize(vEyeNormal),L),0.0f);
    vec3 col = clamp(color*0.2 + color*0.8*NL,0.0f,1.0f);
    gl_FragColor=vec4(col,alpha);
}
